<?php
namespace App\Http\Service\Product;


use App\Http\Service\Basic\BasicService;
use Config;

class ProductService extends BasicService
{
    public function Product()
    {
        return $this->curlLogic->callWebServer(Config::get('custom.setting.BASE_API_PATH') . Config::get('custom.api.product'),'get');

    }

    /**
     * @param $where
     * @return bool|mixed
     * 获取订单列表
     */
    public function Order($where)
    {
     $url = '';
        if(!empty($where))
        {
            $url = '?token='.$where['token'];
        }

        return $this->curlLogic->callWebServer(Config::get('custom.setting.BASE_API_PATH') . Config::get('custom.api.order').$url);
    }

    public function getProductInfo($where)
    {
        $url = '';
        if(!empty($where))
        {
            $url = '?pay_id='.$where['pay_id'];
        }
//        dd(Config::get('custom.setting.BASE_API_PATH') . Config::get('custom.api.product_info').$url);
        return $this->curlLogic->callWebServer(Config::get('custom.setting.BASE_API_PATH') . Config::get('custom.api.product_info').$url);
    }



}